<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>浮动</title>
    <style>
        .div1{
            width: 100px;
            height: 100px;
            background-color: red;
            float: left;
        }
        .div2{
            width: 100px;
            height: 100px;
            background-color: #F0F000;
            float: left;
        }
        .div3{
            width: 100px;
            height: 100px;
            background-color: #0000FF;
            clear: left;
            float: left;
        }
        .div4{
            width: 100px;
            height: 100px;
            background-color: #00FF00;
            float: left;
        }
    </style>
</head>
<body>
    <div class="div1">
        11111

    </div>
    <div class="div2">
        22222

    </div>
    <div class="div3">
        33333

    </div>
    <div class="div4">
        44444

    </div>


</body>
</html>